﻿using QMERP.Domain.Dtos;

namespace QMERP.Application.Services
{
    public interface IUserService
    {
        /// <summary>
        /// 获取当前用户详情(基本信息)
        /// </summary>
        /// <returns></returns>
        Task<CurrentUserResponse> CurrentUser();
        /// <summary>
        /// 用户视图
        /// </summary>
        /// <param name="request"></param>
        /// <returns></returns>
        Task<PageResponse<UserResponse>> Query(PageRequest<UserRequest> request);
        /// <summary>
        /// 获取id的用户详情
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<UserResponse> Detail(long id);
        /// <summary>
        /// 用户保存
        /// </summary>
        /// <param name="request"></param>
        /// <returns></returns>
        Task Save(UserSaveRequest request);
        /// <summary>
        /// 登录
        /// </summary>
        /// <param name="userName"></param>
        /// <param name="password"></param>
        /// <returns></returns>
        /// <exception cref="ApiException"></exception>
        Task<LoginResponse> SignIn(string userName, string password);
        /// <summary>
        /// 根据id获取用户的主要信息
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<MainUserResponse> GetMainUserById(int id);
        /// <summary>
        /// 用户删除(假删除)
        /// </summary>
        /// <returns></returns>
        Task Remove(UserRemoveRequest request);
        /// <summary>
        /// 更新个人信息
        /// </summary>
        /// <param name="info"></param>
        /// <returns></returns>
        //Task ModifyProfile(ProfileRequest info);
        /// <summary>
        /// 修改密码
        /// </summary>
        /// <param name="info"></param>
        /// <returns></returns>
        //Task ChangePassWord(PassWordRequest info);
    }
}
